syntax = "proto3";

package grpc_ex;

// The greeting service definition.
service MainGateway {

  rpc Ctrl_Takeoff (Main_Ctrl_Takeoff_Request) returns (Main_Ctrl_Takeoff_Reply) {}

  rpc Ctrl_Land (Main_Ctrl_Land_Request) returns (Main_Ctrl_Land_Reply) {}

  rpc Ctrl_RTL (Main_Ctrl_RTL_Request) returns (Main_Ctrl_RTL_Reply) {}

  rpc Ctrl_PositionGlobal (Main_Ctrl_PositionGlobal_Request) returns (Main_Ctrl_PositionGlobal_Reply) {}

  rpc Ctrl_PositionNED (Main_Ctrl_PositionNED_Request) returns (Main_Ctrl_PositionNED_Reply) {}
}

// Сообщения основного шлюза БК
message Main_Ctrl_Takeoff_Request {
  double alt_m = 1;
}

message Main_Ctrl_Takeoff_Reply {
  string message = 1;
}

message Main_Ctrl_Land_Request {
  string message = 1;
}

message Main_Ctrl_Land_Reply {
  string message = 1;
}

message Main_Ctrl_RTL_Request {
  string message = 1;
}

message Main_Ctrl_RTL_Reply {
  string message = 1;
}

message Main_Ctrl_PositionGlobal_Request {
  double lat_deg = 1;
  double lon_deg = 2;
  double alt_m = 3;
  double yaw_deg = 4;
}

message Main_Ctrl_PositionGlobal_Reply {
  string message = 1;
}

message Main_Ctrl_PositionNED_Request {
  double north_m = 1;
  double east_m = 2;
  double down_m = 3;
  double yaw_deg = 4;
}

message Main_Ctrl_PositionNED_Reply {
  string message = 1;
}

message Main_Ctrl_Dive_Request {
  string message = 1;
}

message Main_Ctrl_Dive_Reply {
  string message = 1;
}

message Main_MV_PhysTagPos_Request {
  string message = 1;
}

message Main_MV_PhysTagPos_Reply {
  string message = 1;
  double north_m = 2;
  double east_m = 3;
  double down_m = 4;
  double yaw_deg = 5;
}

message Main_MV_VirtTagPos_Request {
  int32 frame_id = 1;
  int32 frame_pos_x = 2;
  int32 frame_pos_y = 3;
}

message Main_MV_VirtTagPos_Reply {
  string message = 1;
  double north_m = 2;
  double east_m = 3;
  double down_m = 4;
  double yaw_deg = 5;
}

